﻿<UserControl x:Class="Tisbi.LawFirm.UI.Views.Controls.Forms.CourtCRUDForm"
             xmlns="http://schemas.microsoft.com/winfx/2006/xaml/presentation"
             xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"
             xmlns:mc="http://schemas.openxmlformats.org/markup-compatibility/2006" 
             xmlns:d="http://schemas.microsoft.com/expression/blend/2008" 
             mc:Ignorable="d" 
             d:DesignHeight="500" d:DesignWidth="380">
    <ScrollViewer>
        <StackPanel Orientation="Vertical">
            <StackPanel.Resources>
                <Style TargetType="StackPanel">
                    <Setter Property="Orientation" Value="Horizontal" />
                    <Setter Property="Margin" Value="0,0,0,4" />
                </Style>
            </StackPanel.Resources>
            <StackPanel>
                <Label Content="№:" Target="{Binding ElementName=TextUuid}"/>
                <TextBox x:Name="TextUuid" Text="{Binding Path=Model.Id}" IsReadOnly="True" Background="LightGray"/>
            </StackPanel>
            <StackPanel>
                <Label Content="Название:" />
                <TextBox Text="{Binding Path=Title, Mode=TwoWay, ValidatesOnDataErrors=True}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Телефон:" />
                <TextBox Text="{Binding Path=Model.Phone, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="ФИО:" />
                <TextBox Text="{Binding Path=Model.FullFio, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Факс:" />
                <TextBox Text="{Binding Path=Model.Fax, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Email:" />
                <TextBox Text="{Binding Path=Model.Email, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Сайт:" />
                <TextBox Text="{Binding Path=Model.Site, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Страна:" />
                <TextBox Text="{Binding Path=Model.Country, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Федеральный округ:" />
                <ComboBox ItemsSource="{Binding Path=Districts}"
                                    SelectedItem="{Binding Path=SelectedDistrict, Mode=TwoWay}" 
                                    DisplayMemberPath="Title" />
            </StackPanel>
            <StackPanel>
                <Label Content="Город:" />
                <TextBox Text="{Binding Path=Model.City, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Индекс:" />
                <TextBox Text="{Binding Path=Model.ZipCode, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Улица:" />
                <TextBox Text="{Binding Path=Model.Street, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Номер дома:" />
                <TextBox Text="{Binding Path=Model.House, Mode=TwoWay}" />
            </StackPanel>
            <StackPanel>
                <Label Content="Корпус:" />
                <TextBox Text="{Binding Path=Model.Housing, Mode=TwoWay}" />
            </StackPanel>
        </StackPanel>
    </ScrollViewer>
</UserControl>
